namespace ScrumSprintMonitor.Infrastructure
{
	#region #using Directives

	using System;
	using System.ComponentModel;

	#endregion

	public enum SprintStatus
	{
		NoDataAvailable,
		OK
	}

	public interface ISprint : INotifyPropertyChanged
	{
		/// <summary>
		/// Name of the sprint
		/// </summary>
		string Name { get; }

		SprintStatus Status { get; }

		Exception Exception { get; }

		/// <summary>
		/// Timestamp of the last successful refresh
		/// </summary>
		DateTime? LastRefresh { get; }

		/// <summary>
		/// Timestamp of the last work item update
		/// </summary>
		DateTime? LastUpdate { get; }

		/// <summary>
		/// Timestamp of the start of the sprint
		/// </summary>
		DateTime Start { get; }

		/// <summary>
		/// Timestamp of the scheduled end of the sprint
		/// </summary>
		DateTime End { get; }

		/// <summary>
		/// Work items assigned to this sprint
		/// </summary>
		IWorkItemStore WorkItemStore { get; }

		/// <summary>
		/// Sum of the man-hours still available to complete this sprint
		/// </summary>
		TimeSpan AvailableTime { get; }

		/// <summary>
		/// Sum of the man-hours available to complete this sprint
		/// </summary>
		TimeSpan TotalTime { get; }

		bool TimeIncludesFreeBusyInformation { get; }

		bool NotAllWorkItemsEstimated { get; }

		/// <summary>
		/// Team members with sprint backlog items assigned to them
		/// </summary>
		BindingList<ITeamMember> TeamMembers { get; }

		ISprintBurndown Burndown { get; }

		void Refresh(bool forceRefresh);
	}
}